home *** CD-ROM | disk | FTP | other *** search
- Subject: Offscreen bitmaps & VDI drawn displays
- Date: Wed, 27 Jul 1994 13:47:11 +1000
- From: Warwick Allison <warwick@cs.uq.oz.au>
- Precedence: bulk
-
-
- Evan K. Langlois:
- >Consider VDI calls. Or a Metafile. Should you save these in some
- >command buffer and then call through the list (of indeterminate size)
- >every time the window needs to be redrawn? What about scrolling?
- >You'll have to clip to a small area and call through a list of VDI commands
- >for every click of the arrow! If the user hold down the arrow button he'll
- >quickly fall asleep!!
-
- You'd be suprised. In the totally naive implementation for my example
- prg, I did exactly this. It's quite fast, and I don't do ANY
- optimization of my collection of VDI calls (I just do them all - an
- optimized solution could store them in a sorted 1 or 2-D array and only
- draw those that might intersect with the area beging redrawn).
-
- What makes it fast is that with clipping turned on, 99% of the VDI
- calls don't do anything (eg. you tell the VDI to draw a circle,
- and it sees that it is completely outside the clip rectangle,
- so returns immediately).
-
- Don't knock it until you've tried it :)
-
- --
- Warwick
-